package com.fortune.dao;

import com.fortune.entity.MRoleUser;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface MRoleUserMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(MRoleUser record);

    int insertSelective(MRoleUser record);

    MRoleUser selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(MRoleUser record);

    int updateByPrimaryKey(MRoleUser record);

    List<String> getRoleIdListByUserId(@Param("userId") int userId);

    List<Integer> getUserIdListByRoleId(@Param("roleId") String roleId);

    void deleteByRoleId(@Param("roleId") String roleId);

    void batchInsert(@Param("roleUserList") List<MRoleUser> roleUserList);

    List<Integer> getUserIdListByRoleIdList(@Param("roleIdList") List<String> roleIdList);

}